package com.boluo.common.utils;

import com.boluo.common.core.redis.RedisCache;

import java.time.LocalDate;

/**
 * @Author boluo
 * @Date 2023/4/11 14:37
 * @注释
 */
public abstract class PhoneUtils {
    /**
     * 校验 电话号码是否正确输出
     * @param phoneNum
     * @return
     */
    public static boolean isPhoneNumber(String phoneNum) {
        if (StringUtils.isEmpty(phoneNum)) {
            return false;
        }
        String regex = "^1[3-9][0-9]{9}$";
        return phoneNum.matches(regex);
    }

    public static void main(String[] args) {
        // 获取当前时间的前一天
        LocalDate localDate = LocalDate.now().minusDays(1);
        System.out.println(localDate.toString());

    }
}
